<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <h2>图书列表</h2>
    <input type="button" value="新增" onclick="btnAdd()">
    <table>
        <tr>
            <th>Id</th>
            <th>书名</th>
            <th>作者</th>
            <th>操作</th>
        </tr>
        {% for item in books %}
        <tr>
            <td>{{item.id}}</td>
            <td>{{item.bookName}}</td>
            <td>{{item.author}}</td>
            <td>
                <input type="button" value="编辑" onclick="btnEdit('{{item.id}}')">
                <input type="button" value="删除" onclick="btnDel(`{{item.id}}`)">
            </td>
        </tr>

        {% endfor %}

    </table>



    <script src="./js/books.js"></script>
</body>
</html>